package com.qlk.test.odcinterface.rest;

import org.junit.Test;
import org.springframework.util.Assert;

import com.qlk.common.client.AbstractClient;
import com.qlk.test.odcinterface.rest.dto.PmsProductPromotionItem;
import com.qlk.test.odcinterface.rest.request.PmsProductPromotionItemRequest;
import com.qlk.test.odcinterface.rest.response.PmsProductPromotionItemResponse;
import com.qlk.test.odcinterface.rest.Urls;

/**
 * PmsProductPromotionItemResource单元测试
 * 
 * @author zhaoyanan
 * @version 2016-4-14 13:22:59
 * 
 */
public class PmsProductPromotionItemResourceTestCase extends AbstractClient {
    
    @Test
    public void testGetPmsProductPromotionItem() {
        String url= Urls.API_DOMAIN + "/pmsProductPromotionItem/getPmsProductPromotionItem";

        PmsProductPromotionItemRequest request = new PmsProductPromotionItemRequest();
        request.setId(1l);
        PmsProductPromotionItemResponse response = super.getRestTemplate().postForObject(url, request, PmsProductPromotionItemResponse.class);
        Assert.notNull(response);
        PmsProductPromotionItem pmsProductPromotionItem = super.getResult(response);
        Assert.notNull(pmsProductPromotionItem);
    }
}
